package DailyPractice.Day13;

import java.util.ArrayList;
import java.util.List;
import java.util.Scanner;

/**
 * 解析参数
 * @author lumin
 * @date 2022/05/09 12:18
 **/
public class Num01 {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        String str = sc.nextLine();
        List<String> ret = new ArrayList<String>();
        int right = str.length();
        int i = -1;
        int n = 0;
        int count = 0;
        while(n + 1 < str.length()){
            if(count == 0 && str.charAt(n) == '"'){
                count = 1;
                i = n + 1;
            }
            if(count == 0){
                if(str.charAt(n) == ' '){
                    ret.add(str.substring(i + 1,n));
                    i = n;
                }
                n++;
            }else{
                if(str.charAt(n + 1) == '"' && count == 1){
                    count = 0;
                    ret.add(str.substring(i,n + 1));
                    i = n;
                }
                n++;
            }
        }
        if(str.charAt(right - 1) != '"'){
            ret.add(str.substring(i + 1,right));
        }
        System.out.println(ret.size());
        for (int j = 0; j < ret.size(); j++) {
            System.out.println(ret.get(j));
        }
    }
}